From 09239eb670208d88bc17997a8bb7319be18b286f Mon Sep 17 00:00:00 2001 From: =?utf8?q?Timm=20B=C3=A4der?= Date: Sun, 29 Oct 2017 17:27:53 +0100 Subject: [PATCH] widget: Don't notify :parent when rearranging widgets gtk_widget_reposition_after is also valid to call if the widget already has a parent, so don't notify the parent property in that case. --- gtk/gtkwidget.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/gtk/gtkwidget.c b/gtk/gtkwidget.c index ebf5dbf147..d60390665c 100644 --- a/gtk/gtkwidget.c +++ b/gtk/gtkwidget.c @@ -8360,7 +8360,9 @@ gtk_widget_reposition_after (GtkWidget *widget, if (priv->parent->priv->anchored && prev_parent == NULL) _gtk_widget_propagate_hierarchy_changed (widget, NULL); - g_object_notify_by_pspec (G_OBJECT (widget), widget_props[PROP_PARENT]); + + if (prev_parent == NULL) + g_object_notify_by_pspec (G_OBJECT (widget), widget_props[PROP_PARENT]); /* Enforce realized/mapped invariants */ -- 2.30.2